Developer Documentation

QuickTime 4 API Documentation

Programming With QuickTime VR

| Previous | Chapter Contents | Chapter Top | Next |

Initializing and Managing QuickTime VR Movie Instances

The QuickTime VR Manager provides routines for obtaining a QTVR track and a new movie instance.

QTVRGetQTVRTrack

You can use the QTVRGetQTVRTrack function to get a QTVR track contained in a QuickTime movie to use in the QTVRGetQTVRInstance call.

Track QTVRGetQTVRTrack (Movie theMovie, SInt32 index);
theMovie
A QuickTime movie.
index
The index of the desired QTVR track.
function result
A track identifier for the QTVR track having the specified index in the specified QuickTime movie.

DESCRIPTION

The QTVRGetQTVRTrack function returns, as its function result, a track identifier for the QTVR track that has the index specified by the index parameter in the QuickTime movie specified by the theMovie parameter. If there is no such track, QTVRGetQTVRTrack returns the value nil .

SPECIAL CONSIDERATIONS

QuickTime VR 2.1 supports files with at most one QTVR track, hence the value for the index parameter should always be one. Future versions may support multiple QTVR tracks per file.

Panorama and object movies made with QuickTime VR version 1.0 have no QTVR track. The QTVRGetQTVRTrack function returns the track ID of the panorama track for version 1.0 panorama movies and the track ID of the image video track for version 1.0 object movies. For non-QTVR movies, the QTVRGetQTVRTrack function returns nil.

SEE ALSO

Use QTVRGetQTVRInstance (next) to get a QuickTime VR movie instance from the track identifier returned by QTVRGetQTVRTrack .

QTVRGetQTVRInstance

You can use the QTVRGetQTVRInstance function to get an instance of a QuickTime VR movie.

OSErr QTVRGetQTVRInstance (
                     QTVRInstance *qtvr,
                     Track qtvrTrack,
                     MovieControllermc);
qtvr
On exit, an instance of the specified QuickTime VR movie.
qtvrTrack
A QTVR track contained in a QuickTime movie. You can obtain a reference to this track by calling QTVRGetQTVRTrack .
mc
An identifier for the movie controller to be associated with the new QuickTime VR movie instance. You can get a movie controller identifier by calling the NewMovieController function.
function result
A result code.

DESCRIPTION

The QTVRGetQTVRInstance function returns, in the qtvr parameter, an instance of the QuickTime VR movie specified by the qtvrTrack parameter. If qtvrTrack does not specify a QTVR track, QTVRGetQTVRInstance returns nil in the qtvr parameter and an error code as its function result. You need a QuickTime VR movie instance to call most other QuickTime VR functions.

SPECIAL CONSIDERATIONS

It's not necessary to dispose of a QuickTime VR movie instance.


© 1998 Apple Computer, Inc.

| Previous | Chapter Contents | Chapter Top | Next |